/*
 * MyCenter.h
 *
 *  Created on: 2013-2-4
 *      Author: Administrator
 */

#ifndef MYCENTER_H_
#define MYCENTER_H_

#include <qlabel.h>
#include <qpushbutton.h>
#include <qtablewidget.h>
#include <qwidget.h>
#include <qlayout.h>
#include <qsqlrelationaltablemodel.h>
#include "../bo/CostType.h"
#include "../utile/DAObject.h"
#include "ModifyUser.h"
class MyCenter : public QWidget
{
	Q_OBJECT
public:
	MyCenter(const QString &uname, const quint32 &uid, QWidget *parent = 0);
	virtual ~MyCenter();
private Q_SLOTS:
void slt_setMode();
void slt_modifyPsw(const int &mode, const int &id, const QString &name, const QString &signName,
		const int &type, const bool &locked, const QString &password);
private:
	void initUi();
	void initTableOn();
	void initTableFinished();
	QPushButton modifyPswButton, exitButton, budgetMakeButton,
		budgetViewButton, budgetFinishedViewButton;
	QLabel welcomeLabel, myProjectLabel, projectOnLabel, projectFinishedLabel;
	QTableWidget tableOn, tableFinished;
	QGridLayout layout;
	QSqlDatabase db;
	QSqlRelationalTableModel *tableMode;
	ModifyUser modifyPswd;
	quint32 uid;
};

#endif /* MYCENTER_H_ */
